home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Users Group Library 1996 July / C-C++ Users Group Library July 1996.iso / vol_400 / 409_01 / vesavbe.h < prev    next >
C/C++ Source or Header  |  1993-10-21  |  4KB  |  80 lines

  1. /****************************************************************************
  2. *
  3. *                         The SuperVGA Test Kit
  4. *
  5. *                   Copyright (C) 1993 SciTech Software.
  6. *                           All rights reserved.
  7. *
  8. * Filename:     $RCSfile: vesavbe.h $
  9. * Version:      $Revision: 1.1 $
  10. *
  11. * Language:     ANSI C
  12. * Environment:  IBM PC (MS DOS)
  13. *
  14. * Description:  Header file declaring the structures used to comminucate
  15. *               with a VESA VBE compliant BIOS.
  16. *
  17. *               MUST be compiled in the large model.
  18. *
  19. * $Id: vesavbe.h 1.1 1993/10/22 08:59:44 kjb release $
  20. *
  21. ****************************************************************************/
  22.  
  23. #ifndef __VESAVBE_H
  24. #define __VESAVBE_H
  25.  
  26. #ifndef __DEBUG_H
  27. #include "debug.h"
  28. #endif
  29.  
  30. /*---------------------- Macros and type definitions ----------------------*/
  31.  
  32. /* SuperVGA information block */
  33.  
  34. typedef struct {
  35.     char    VESASignature[4];       /* 'VESA' 4 byte signature          */
  36.     short   VESAVersion;            /* VBE version number               */
  37.     char    *OEMStringPtr;          /* Pointer to OEM string            */
  38.     long    Capabilities;           /* Capabilities of video card       */
  39.     short   *VideoModePtr;          /* Pointer to supported modes       */
  40.     short   TotalMemory;            /* Number of 64kb memory blocks     */
  41.     char    reserved[236];          /* Pad to 256 byte block size       */
  42.     } VgaInfoBlock;
  43.  
  44. /* SuperVGA mode information block */
  45.  
  46. typedef struct {
  47.     short   ModeAttributes;         /* Mode attributes                  */
  48.     char    WinAAttributes;         /* Window A attributes              */
  49.     char    WinBAttributes;         /* Window B attributes              */
  50.     short   WinGranularity;         /* Window granularity in k          */
  51.     short   WinSize;                /* Window size in k                 */
  52.     short   WinASegment;            /* Window A segment                 */
  53.     short   WinBSegment;            /* Window B segment                 */
  54.     void    *WinFuncPtr;            /* Pointer to window function       */
  55.     short   BytesPerScanLine;       /* Bytes per scanline               */
  56.     short   XResolution;            /* Horizontal resolution            */
  57.     short   YResolution;            /* Vertical resolution              */
  58.     char    XCharSize;              /* Character cell width             */
  59.     char    YCharSize;              /* Character cell height            */
  60.     char    NumberOfPlanes;         /* Number of memory planes          */
  61.     char    BitsPerPixel;           /* Bits per pixel                   */
  62.     char    NumberOfBanks;          /* Number of CGA style banks        */
  63.     char    MemoryModel;            /* Memory model type                */
  64.     char    BankSize;               /* Size of CGA style banks          */
  65.     char    NumberOfImagePages;     /* Number of images pages           */
  66.     char    res1;                   /* Reserved                         */
  67.     char    RedMaskSize;            /* Size of direct color red mask    */
  68.     char    RedFieldPosition;       /* Bit posn of lsb of red mask      */
  69.     char    GreenMaskSize;          /* Size of direct color green mask  */
  70.     char    GreenFieldPosition;     /* Bit posn of lsb of green mask    */
  71.     char    BlueMaskSize;           /* Size of direct color blue mask   */
  72.     char    BlueFieldPosition;      /* Bit posn of lsb of blue mask     */
  73.     char    RsvdMaskSize;           /* Size of direct color res mask    */
  74.     char    RsvdFieldPosition;      /* Bit posn of lsb of res mask      */
  75.     char    DirectColorModeInfo;    /* Direct color mode attributes     */
  76.     char    res2[216];              /* Pad to 256 byte block size       */
  77.     } ModeInfoBlock;
  78.  
  79. #endif  /* __VESAVBE_H */
  80.